home *** CD-ROM | disk | FTP | other *** search
- // Figure 9 for "A Little CAD with C++"
- // Copyright 1988 Bruce Eckel
- // Permission required to distribute source
-
- // file: line.hpp
- #ifndef LINE_HPP
- #define LINE_HPP
- #include <fg.h>
- #include "cadshape.hpp"
-
- class line : public cadshape {
- fg_line_t line_data;
- public:
- void draw();
- line(unsigned x, unsigned y): () {
- x_center = x; y_center = y;
- draw();
- }
- void erase();
- ~line() { erase(); }
- };
- #endif LINE_HPP